import { getMap } from "echarts";
// import axios from "../api/request";
import axios from "axios";

//今日热点api

const base = {
    baseURL:"https://api.tianapi.com",
    ncov:"/ncov/index",
    //mapDataURL:"http://49.4.25.117/JKZX/yq_20200719.json",
    socialURL:"/social/index",
    entertainmentURL:"/huabian/index",
    sportsURL:"/tiyu/index",
    technologyURL:"/keji/index",
}

const api = {
    // 疫情数据
    getNcov(params){
        return axios.get(base.baseURL + base.ncov,{
            params
        })
    },
    // getMapData(){
    //     return axios.get(base.mapDataURL,{
    //     })
    // },
    getSocial(params){
        return axios.get(base.baseURL + base.socialURL,{
            params
        })
    },
    getEntertain(params){
        return axios.get(base.baseURL + base.entertainmentURL,{
            params
        })
    },
    getSports(params){
        return axios.get(base.baseURL + base.sportsURL,{
            params
        })
    },
    getTechnology(params){
        return axios.get(base.baseURL + base.technologyURL,{
            params
        })
    }
}
export default api;